package com.atguigu.springcloud.dao;

import com.atguigu.springcloud.entities.Payment;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

/**
 * @author xiaolong
 * @version 1.0
 * @description: TODO
 * @date 2021/9/2 15:48
 */
@Mapper
@Repository
public interface PaymentDao {

    /**
     * @param payment
     * @return int
     * @description: 添加操作
     */
    public int create(Payment payment);

    /**
     * @param id
     * @return Payment
     * @description: 加上@Param注解，mapper中就可以采用#{}的方式把@Param注解括号内的参数进行引用
     */
    public Payment getPaymentById(@Param("id") Long id);

}
